package com.sander.guardmanagement.response;

import android.text.TextUtils;

import java.io.Serializable;

/**
 * Created by sander on 2017/4/25.
 */

public class ResponseHomeGetUserHomeListData implements Serializable {

    public int id; //家庭地址ID

    public int city_id; // 城市ID

    public String city_name;//城市名称

    public int community_id;//小区ID

    public String community_name;//小区名称

    public int soncommunityid;//期数ID

    public String sub_community_name;//期数名称

    public int building_id;//楼栋/单元ID

    public String build_name;//楼栋/单元名称

    public  int room_id;//房间ID

    public String room_name;//房间名称

    public int user_id;//用户ID

    public int type;//类型：1为业主用户，2为租客用户

    public int status;//状态，0待审核，1为已经审核通过 2审核未通过

    public String createTime;//创建时间


    public String getAdress(){

        if (TextUtils.isEmpty(city_name))city_name = "";
        if (TextUtils.isEmpty(community_name))community_name = "";
        if (TextUtils.isEmpty(sub_community_name))sub_community_name = "";
        if (TextUtils.isEmpty(build_name))build_name = "";
        if (TextUtils.isEmpty(room_name))room_name = "";

        return city_name + community_name + "\n" + sub_community_name + build_name + room_name;
    }

}
